package org.zsl.entity;

import org.junit.Test;
import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

public class CustomerTestor {


    @Test
    public void testGetCustomerInstance() {

        Customer customer = new Customer();
        System.out.println(customer);
    }


    @Test
    public void testGetCustomerInstanceForXML() {


         Customer customer1 = new Customer();


        ApplicationContext context = new ClassPathXmlApplicationContext("beans.xml");
        Customer customer = (Customer) context.getBean("customer2");

        // customer.setName("dd");


        System.out.println(customer.getGender());


    }
}
